#!/bin/bash

DATE=`date -d "now" +"%Y-%m-%d %H:%M:%S"`

counts=`ps -ef | grep "\./onevone" | grep -v grep | wc -l`
echo $counts
if [ $counts -eq 0 ]
 then
 echo  "$DATE onevone is restart"
 cd /srv/onevone/ && ./onevone &
else
 echo  "$DATE onevone is running"
fi